class AddInvitationsTable < ActiveRecord::Migration
  def self.up
    create_table :invitations do |t|
      t.column :group_id, :integer, :null => false
      t.column :access_key, :string, :limit=>40, :null => false
    end
    add_index :invitations, [:group_id, :access_key], :unique
  end

  def self.down
    drop_table :invitations
  end
end